<!DOCTYPE html>
<!-- v1.6.7.2 RDPROJECT-569 cx 2013-12-26 start -->
<html>
<#include "../../head.html">
    <body>
    <table class="mc">
        <tr>
            <td class="mc-l">
                <!--左侧导航---{-->
                <div id="navPanelContainer">
                    <div class="system-logo cd"></div>
                    <!--管理员信息---{-->
                    <#include "../../adminInfo.html">
                        <!--管理员信息---}-->
                        <div class="nav-wrap">
                            <#include "../left.html">
                        </div>
                </div>
                <!--左侧导航---}-->
            </td>
            <td class="mc-m">
                <div class="navToggle"></div>
            </td>
            <td class="mc-r">
                <!--顶部导航---{-->
                <#include "../../topNav.html">
                    <!--顶部导航---}-->

                    <!--面包屑导航---{-->
                    <#assign moduleName="新增积分商品">
                        <#include "../banner.html">
                            <!--面包屑导航---}-->

                            <!--工具栏--{-->
                            <div id="toolbar" class="clearfix">
                                <div class="toolbor-module search">
                                    <input type="button" class="input-button return" value="返回" onclick="location.href='goodsCatagoryList.html'">
                                </div>
                            </div>
                            <!--工具栏--}-->

                            <div id="main" class="clearfix">
                                <form name="childForm" method="post" action="${request.getContextPath()}/admin/credit/addGoodsCategory.html?type=child"  enctype="multipart/form-data" >
                                    <div class="valBox w750">
                                        <div class="top">
                                            <strong>新增积分商品</strong>
                                        </div>
                                        <div class="val clearfix">
                                            <ul>
                                            	<li>
                                            		<div class="title">商品分类：</div>
                                            			<div class="v">
                                            			<select id="parent_id" name="parent_id">
                                                    		<option value=""></option>
                                                    		<#list parentList as item>
                                                    		<option value="${item.id}">${item.name}</option>
                                                    		</#list>
                                                    	</select>
                                            			</div>
                                            	</li>
                                                <li>
                                                    <div class="title">商品名称：</div>
                                                    <div class="v">
                                                        <input type="text" id="child_name" name="child_name"/>
                                                    </div>
                                                </li>
                                                  <li>
                                                	<div class="title">类别：</div>
                                                	<div class="v">
                                                		<select id="is_virtual" name="is_virtual">
                                                			<option value="-1">请选择</option>
                                                			<option value="0">实物</option>
                                                			<option value="1">vip</option>
                                                			<option value="2">现金</option>
                                                		</select>
                                                	</div>
                                                 </li>
                                            </ul>
                                            <div class="other">
                                                <input type="hidden"  name="actionType" value="addGoodsCategory" />
                                                <input type="button"  value="新增" onclick="addChildGoodsCategory();" class="input-button confirm"/>
                                            </div>
                                        </div>
                                    </div>

                                </form>

                            </div>
            </td>
        </tr>
        <tr>
            <!--尾部--{-->
            <td colspan="3" class="mc-b"><#include "../../foot.html"></td>
            <!--尾部--}-->
        </tr>
    </table>
   <script type="text/javascript">
   		function addChildGoodsCategory(){
   			if($('#parent_id').val()==''){
   				alert("请输入商品分类！");
   				return false;
   			}
   			if($('#child_name').val()==''){
   				alert("请输入商品名称！");
   				return false;
   			}
   			if($('#is_virtual').val()=='' || $('#is_virtual').val()=='-1'){
   				alert("请选择商品类别");
   				return false;
   			}
   			document.forms["childForm"].submit();
   		}
   
   </script> 
<div class="msgClass"> ${rsmsg!""}</div>
    </body>
</html>
<#include "../../jsPage.html">
<!-- v1.6.7.2 RDPROJECT-569 cx 2013-12-26 start -->
